using System;
using System.Collections.Generic;
using System.Text;
using SP.Parameter;

namespace SP.HwLowProfileRS
{
    /// <summary>
    /// A simple base map feature
    /// </summary>
    public class VertexAlphaFusion : AbstractFusion
    {
        public VertexAlphaFusion()
        {
        }

        public override string Name
        {
            get { return "VertexAlpha"; }
        }

        public override string Desc
        {
            get { return "Enable this fusion to support vertex alpha effect."; }
        }

        public override Stage Stage
        {
            get { return Stage.Opacity; }
        }

        public override int UVChannelCount
        {
            get { return 0; }
        }

        public override void Code(StringBuilder b, string platform)
        {
            AddLine(b, "pipeline.Opacity *= input.Color.r;");
        }
    }
}
